<template>
  <div class="item-box">
    <div
      class="item"
      v-for="(item, index) in subcategories.list"
      :key="index.id"
    >
      <a :href="item.link">
        <img class="item-img" :src="item.image" alt="" />
        <div class="item-text">{{ item.title }}</div>
      </a>
    </div>
  </div>
</template>

<script>
export default {
  name: "TabContentCategory",
  props: {
    subcategories: {
      type: Object,
      default() {
        return {};
      }
    }
  }
};
</script>

<style scoped>
.item-box {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.item {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 81px;
  font-size: 12px;
  margin: 8px 5px;
}

.item-img {
  width: 75px;
  height: 75px;
}

.item-text {
  margin-top: 15px;
  text-align: center;
}
</style>
